﻿using Furion.DatabaseAccessor;
using Microsoft.EntityFrameworkCore;
using XinGuanERP.Models.Po.business;
using XinGuanERP.Models.Po.system;
using XinGuanERP.Models.Vo.business;

namespace XinGuanERP.Db
{
    [AppDbContext("MySqlConnectionString", DbProvider.MySqlOfficial)]
    public class DefaultDbContext : AppDbContext<DefaultDbContext>
    {
        public DefaultDbContext(DbContextOptions<DefaultDbContext> options) : base(options)
        {
        }

        #region system
        public DbSet<User> Users { get; set; }
        public DbSet<Role> Roles { get; set; }
        public DbSet<Dept> Depts { get; set; }
        public DbSet<SysActionLog> SysActionLogs { get; set; }
        public DbSet<Dict> Dicts { get; set; }
        public DbSet<DictEntry> DictEntries { get; set; }
        public DbSet<SysMenu> SysMenus { get; set; }
        public DbSet<SysRoleMenu> SysRoleMenus { get; set; }
        #endregion

        #region business
        public DbSet<Product> Products { get; set; }
        public DbSet<ProductStock> ProductStocks { get; set; }
        public DbSet<ProductCategory> ProductCategories { get; set; }
        public DbSet<InStock> InStocks { get; set; }
        public DbSet<OutStock> OutStocks { get; set; }
        public DbSet<Suppiler> Suppilers { get; set; }
        public DbSet<Consumer> Consumers { get; set; }

        #endregion

    }
}
